<template>
  <div class="meFriends">
    <div class="header">
      <div class="top">
        <div class="left">
          <div class="back" @click="back">
            <van-icon name="arrow-left" size="25" />
          </div>
          <div class="title">我的好友</div>
        </div>
        <div class="right">
          <van-icon name="friends-o" size="25" />
        </div>
      </div>
      <div class="navBox">
        <div class="nav">
          <router-link to="meFollow" replace>关注</router-link>
        </div>
        <div class="nav">
          <router-link to="meFans" replace>粉丝</router-link>
        </div>
      </div>
    </div>
    <div class="likeheader"></div>
    <RouterView />
  </div>
</template>

<script setup lang="ts">
const back = () => {
  history.go(-1);
};
</script>

<style lang="scss" scoped>
.meFriends {
  background-color: #f3f3f0;
  height: 100vh;

  .header {
    position: fixed;
    left: 0;
    top: 0;
    width: 100vw;
    background-color: white;

    .top {
      display: flex;
      align-items: center;
      justify-content: space-between;
      height: 50px;
      border-bottom: 1px solid #e2e2e2;
      box-sizing: border-box;

      .left {
        margin-left: 15px;
        display: flex;
        align-items: center;

        .back {
          width: 25px;
          height: 25px;
          cursor: pointer;
        }

        .title {
          margin-left: 33px;
          font-weight: bold;
          font-size: 20px;
        }
      }

      .right {
        margin-right: 14px;
        cursor: pointer;
      }
    }

    .navBox {
      height: 40px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      border-bottom: 1px solid #e2e2e2;
      box-sizing: border-box;

      .nav:first-of-type {
        margin-left: 80px;
        margin-right: 0;
      }

      .nav {
        display: flex;
        align-items: center;
        justify-content: center;
        height: 20px;
        line-height: 20px;
        margin-right: 90px;

        a {
          font-size: 16px;
          color: #999;
        }

        .router-link-active {
          font-weight: bold;
          color: #000;
        }
      }
    }
  }

  .likeheader {
    height: 90px;
  }
}
</style>
